<template>
  <div>
    <el-dialog :title="title" :visible.sync="showDialog" :before-close="dialogFormVisible" width="65%" style="margin-top:5%;margin-left:10%; ">
      <el-form :model="form">
        <div style="display:flex">
          <el-row style="width:50%" :gutter="20">
            <el-col :span="8">
              <el-form-item size="small" class="Dh_item" label="检票车次" :label-width="formLabelWidth"> <el-input size="small" v-model="form.internet_quantity"></el-input> </el-form-item
            ></el-col>
            <el-col :span="8">
              <el-form-item size="small" class="Dh_item" label="检票时间" :label-width="formLabelWidth"> <el-input size="small" v-model="form.internet_quantity"></el-input> </el-form-item
            ></el-col>
            <el-col :span="8">
              <el-form-item size="small" class="Dh_item" label="开往" :label-width="formLabelWidth"> <el-input size="small" v-model="form.internet_quantity"></el-input> </el-form-item
            ></el-col>
          </el-row>
          <el-row style="width:50%;margin-left:30px">
            <div>检票时间已到</div>
          </el-row>
        </div>

        <el-row :gutter="20">
          <el-col :span="6">
            <el-form-item size="small" class="Dh_item" label="车次类型" :label-width="formLabelWidth"> <el-input size="small" v-model="form.internet_quantity"></el-input> </el-form-item
          ></el-col>
          <el-col :span="6">
            <el-form-item size="small" class="Dh_item" label="车辆" :label-width="formLabelWidth"> <el-input size="small" v-model="form.internet_quantity"></el-input> </el-form-item
          ></el-col>
          <el-col :span="6">
            <el-form-item size="small" class="Dh_item" label="售票数" :label-width="formLabelWidth"> <el-input size="small" v-model="form.internet_quantity"></el-input> </el-form-item
          ></el-col>
          <el-col :span="6">
            <el-form-item size="small" class="Dh_item" label="是否拆分" :label-width="formLabelWidth"> <el-input size="small" v-model="form.internet_quantity"></el-input> </el-form-item
          ></el-col>
        </el-row>

        <el-row :gutter="20">
          <el-col :span="6">
            <el-form-item size="small" class="Dh_item" label="售票数" :label-width="formLabelWidth"> <el-input size="small" v-model="form.internet_quantity"></el-input> </el-form-item
          ></el-col>
          <el-col :span="6">
            <el-form-item size="small" class="Dh_item" label="是否拆分" :label-width="formLabelWidth"> <el-input size="small" v-model="form.internet_quantity"></el-input> </el-form-item
          ></el-col>
          <el-col :span="6">
            <el-form-item size="small" class="Dh_item" label="车主" :label-width="formLabelWidth"> <el-input size="small" v-model="form.internet_quantity"></el-input> </el-form-item
          ></el-col>
          <el-col :span="6">
            <el-form-item size="small" class="Dh_item" label="车型" :label-width="formLabelWidth"> <el-input size="small" v-model="form.internet_quantity"></el-input> </el-form-item
          ></el-col>
        </el-row>

        <el-row :gutter="20">
          <el-col :span="6">
            <el-form-item size="small" class="Dh_item" label="所属公司" :label-width="formLabelWidth"> <el-input size="small" v-model="form.internet_quantity"></el-input> </el-form-item
          ></el-col>
        </el-row>
      </el-form>
      <div class="btn">
        <el-button type="primary" @click="updates" class="update">开始检票</el-button>
        <el-button type="info" @click="dialogFormVisible" class="close">取消 </el-button>
      </div>
      <!-- 环境车次票价 -->
    </el-dialog>
  </div>
</template>
<script>
// const api = $api.dispatch.env_bus_Info
export default {
  props: ['show'],
  data() {
    return {
      title: '',
      showDialog: false,
      form: {},
      formLabelWidth: '70px'
    }
  },
  mounted() {
    this.showDialog = this.show
    this.title = '启动检票'
  },
  methods: {
    updates() {},
    //关闭弹窗
    dialogFormVisible() {
      this.showDialog = false
      this.$emit('hide')
    },
    // 日期格式转换
    getTime(dateData) {
      let date = new Date(dateData)
      let y = date.getFullYear()
      let m = date.getMonth() + 1
      m = m < 10 ? '0' + m : m
      let d = date.getDate()
      d = d < 10 ? '0' + d : d
      const time = y + '-' + m + '-' + d
      return time
    }
  }
}
</script>
<style scoped>
.btn {
  text-align: center;
}
</style>
